package com.smart.entity.business;


import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.smart.model.excel.annotation.ExcelField;
import com.smart.model.excel.annotation.ExcelFields;
import com.smart.mybatis.entity.BaseEntity;
import java.util.Date;
import com.smart.mybatis.annotation.Column;
import com.smart.mybatis.enums.QueryType;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.FieldNameConstants;
import lombok.NoArgsConstructor;

/**
 * final
 *
 * @author wf
 * @since 2025-04-30 11:30:33
 */
@EqualsAndHashCode(callSuper = true)
@Data
@AllArgsConstructor
@NoArgsConstructor
@FieldNameConstants
@TableName("jwzn_ele_data")
@ExcelFields({
        @ExcelField(title = "序号", attrName = "listId",  align = ExcelField.Align.CENTER, sort = 1),
        @ExcelField(title = "点位名称", attrName = "name",  dictCode = "business_data", align = ExcelField.Align.CENTER, sort = 2),
        @ExcelField(title = "总电量(Kwh)", attrName = "totalEle",  align = ExcelField.Align.CENTER, sort = 3),
        @ExcelField(title = "消耗值", attrName = "consume",  align = ExcelField.Align.CENTER, sort = 4),
        @ExcelField(title = "状态", attrName = "status",  align = ExcelField.Align.CENTER, sort = 5),
        @ExcelField(title = "采集时间", attrName = "pickTime",  align = ExcelField.Align.CENTER, sort = 6)
})
public class JwznEleDataEntity extends BaseEntity {
    private static final long serialVersionUID = 1L;
    /**
     * 序号
     */
    @Column(isNull = false)
    private Integer listId;
    /**
     * 点位名称
     */
    @Column(name = "name", queryType = QueryType.EQ)
    private String name;
    /**
     * 总电量(Kwh)
     */
    private Double totalEle;
    /**
     * 消耗值
     */
    private Double consume;
    /**
     * 状态
     */
    @Column(name = "status", queryType = QueryType.EQ)
    private String status;
    /**
     * 采集时间
     */
    @Column(isNull = false)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss" ,timezone="GMT+8")
    private Date pickTime;

}

